Recent advances in computer performance have enabled graphic systems to provide more realistic graphical images using personal computers, home video game computers, handheld devices, and the like. In such graphic systems, a number of procedures are executed to “render” or draw graphic primitives to the screen of the system. A “graphic primitive” is a basic component of a graphic picture, such as a point, line, polygon, or the like. Rendered images are formed with combinations of these graphic primitives. Many procedures may be utilized to perform 3-D graphics rendering.
Specialized graphics processing units (e.g., GPUs, etc.) have been developed to optimize the computations required in executing the graphics rendering procedures. The GPUs are configured for high-speed operation and typically incorporate one or more rendering pipelines. Each pipeline includes a number of hardware-based functional units that are optimized for high-speed execution of graphics instructions/data, where the instructions/data are fed into the front end of the pipeline and the computed results emerge at the back end of the pipeline. The hardware-based functional units, cache memories, firmware, and the like, of the GPU are optimized to operate on the low-level graphics primitives and produce real-time rendered 3-D images.
The computational resources of the GPU are increasingly being used to handle compute intensive tasks other than 3-D graphics processing. One such task is to use GPU resources to accelerate video processing operations, and one such video processing operation involves the acceleration of JPEG encoding.
As commonly used, JPEG (Joint Photographic Experts Group) refers to a standardized method for the compression of images. The JPEG standard specifies both the codec, which defines how an image is compressed into a stream of bytes and decompressed back into an image, and the file format used to contain that stream. The compression method implemented by the codec is usually lossy, meaning that some visual quality is lost in the process, although there are variations on the JPEG codec that can implement lossless compression.
It is important that the JPEG codec is efficiently executed in order to provide sufficient responsiveness and interactivity for a user. For example, in a real-time image compression application (e.g., web cam, digital camera, etc.) is important that sufficient processing power is provided to ensure smooth image output and good application responsiveness.
A problem exists in the fact that quantization is one of the key steps in typical JPEG codecs. For example, linear quantization, which is commonly used in JPEG codecs, involves the implementation of a division operation. Unfortunately, division operations are usually very expensive for most computing platforms. Because of this, typical prior art computer platforms for implementing real-time JPEG codec execution can be overpowered, in that they comprise an excessively large number of computer resources in order to deliver sufficient responsiveness, image quality, and interactivity, and thus consume too much power (e.g., which is harmful to handheld applications). Alternatively, other prior art computer platforms, to conserve power consumption, sacrifice responsiveness, image quality, or interactivity in order to achieve acceptable battery performance.
Thus, a need exists for a solution that can yield improved codec execution performance without sacrificing application responsiveness, image quality, or user interactivity.